package com.panda.mall.common.mallCoupon.entity;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Size;
import javax.validation.constraints.NotNull;

import java.io.Serializable;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.panda.mall.common.base.BaseEntity;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import org.hibernate.validator.constraints.Length;

/**
* 优惠秒杀活动场次表
* mall_coupon_seckill_session
*/
@EqualsAndHashCode(callSuper = true)
@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName("mall_coupon_seckill_session")
public class MallCouponSeckillSession extends BaseEntity implements Serializable {

    /**
    * 活动id
    */
    @NotNull(message="[活动id]不能为空")
    @ApiModelProperty("活动id")
    private Long id;
    /**
    * 场次名称
    */
    @Size(max= 255,message="编码长度不能超过255")
    @ApiModelProperty("场次名称")
    @Length(max= 255,message="编码长度不能超过255")
    private String name;
    /**
    * 开始时间
    */
    @ApiModelProperty("开始时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date startTime;
    /**
    * 结束时间
    */
    @ApiModelProperty("结束时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date endTime;
    /**
    * 创建人id
    */
    @ApiModelProperty("创建人id")
    private Long createId;

}
